package com.example.jf.jfapp.bean.request;

import android.os.Parcel;
import android.os.Parcelable;

import java.util.ArrayList;

/**
 * Created by jf on 2017/7/27.
 */

public class DongTaiListRequest implements Parcelable {
    String headProtrait;
    String userId;
    String userName;
    int commentsSize;
    ArrayList<String>imageUrls;
    String message;
    int praiseSize;
    boolean praiseStatus;
    String statuId;
    long  timestamp;

    protected DongTaiListRequest(Parcel in) {
        headProtrait = in.readString();
        userId = in.readString();
        userName = in.readString();
        commentsSize = in.readInt();
        imageUrls = in.createStringArrayList();
        message = in.readString();
        praiseSize = in.readInt();
        praiseStatus = in.readByte() != 0;
        statuId = in.readString();
        timestamp = in.readInt();
    }

    public static final Creator<DongTaiListRequest> CREATOR = new Creator<DongTaiListRequest>() {
        @Override
        public DongTaiListRequest createFromParcel(Parcel in) {
            return new DongTaiListRequest(in);
        }

        @Override
        public DongTaiListRequest[] newArray(int size) {
            return new DongTaiListRequest[size];
        }
    };

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(headProtrait);
        dest.writeString(userId);
        dest.writeString(userName);
        dest.writeInt(commentsSize);
        dest.writeStringList(imageUrls);
        dest.writeString(message);
        dest.writeInt(praiseSize);
        dest.writeByte((byte) (praiseStatus ? 1 : 0));
        dest.writeString(statuId);
        dest.writeLong(timestamp);



    }

    public DongTaiListRequest(String headProtrait,
                              String userId,
                              String userName,
                              int commentsSize,
                              ArrayList<String> imageUrls,
                              String message,
                              int praiseSize,
                              boolean praiseStatus,
                              String statuId, long timestamp) {
        this.headProtrait = headProtrait;
        this.userId = userId;
        this.userName = userName;
        this.commentsSize = commentsSize;
        this.imageUrls = imageUrls;
        this.message = message;
        this.praiseSize = praiseSize;
        this.praiseStatus = praiseStatus;
        this.statuId = statuId;
        this.timestamp = timestamp;
    }

    public String getHeadProtrait() {
        return headProtrait;
    }

    public void setHeadProtrait(String headProtrait) {
        this.headProtrait = headProtrait;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public int getCommentsSize() {
        return commentsSize;
    }

    public void setCommentsSize(int commentsSize) {
        this.commentsSize = commentsSize;
    }

    public ArrayList<String> getImageUrls() {
        return imageUrls;
    }

    public void setImageUrls(ArrayList<String> imageUrls) {
        this.imageUrls = imageUrls;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public int getPraiseSize() {
        return praiseSize;
    }

    public void setPraiseSize(int praiseSize) {
        this.praiseSize = praiseSize;
    }

    public boolean isPraiseStatus() {
        return praiseStatus;
    }

    public void setPraiseStatus(boolean praiseStatus) {
        this.praiseStatus = praiseStatus;
    }

    public String getStatuId() {
        return statuId;
    }

    public void setStatuId(String statuId) {
        this.statuId = statuId;
    }

    public long getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(long timestamp) {
        this.timestamp = timestamp;
    }
}
